The present invention relates to a three-dimensional CAD (three-dimensional computer aided design: 3D-CAD) system, particularly to a three-dimensional CAD system applying a basic geometric theory called xe2x80x9ctopology CADxe2x80x9d (topology-applied CAD), and the recording medium utilized for the system.
Currently, a system called a xe2x80x9cthree-dimensional CADxe2x80x9d is widely noticed, which enables the user to create a three-dimensional design using a computer. Most of the conventionally used 3D-CAD applies a method so-called a xe2x80x9csolid CAD using Boolean expressionxe2x80x9d.
According to the method of solid CAD using Boolean expression, in order to define a solid graphic as shown in FIG. 1 [1] where a cylinder CY penetrates above a square box BX, two basic graphics, the cylinder CY and the solid BX, are superposed, the intersection curve(trim line) TL of surface S1 and surface S2 is computed, and a xe2x80x9ctrimming processxe2x80x9d is performed thereto where unnecessary portion of the surfaces are removed. Moreover, the Boolean operation tends to create an angular or boxy graphic, so it is necessary to provide thereto a process called a xe2x80x9cfillet processxe2x80x9d where the angular surfaces are rounded using a fillet surface FS. However, both the trim line TL and the fillet surface FS are approximate solutions, and accurately, the surfaces are not connected to each other.
Generally, the three-dimensional curved surface within a three-dimensional rectangular coordinate system having x, y, z axes representing real space is mathematically expressed as shown in the following equation (1):
f(x, y, z)=0xe2x80x83xe2x80x83(1)
However, according to conventional CAD system, parameters (xcex1, xcex2) are commonly used to represent a point (x, y, z) within a rectangular coordinate system as shown in the following equation (2):
(x, y, z)=S(xcex1, xcex2)xe2x80x83xe2x80x83(2)
wherein S is a vector function.
Here, we will refer to this surface (plane) defined by (xcex1, xcex2) as a xe2x80x9cparameter planexe2x80x9d, and the surface in real-space defined by a group of infinite points (x, y, z) corresponding to this parameter plane (xcex1, xcex2) is referred to as xe2x80x9cmapped planexe2x80x9d.
In this case, according to a normal CAD method, as shown in FIG. 2, the parameter plane (xcex1, xcex2) is defined by a regular quadrilateral shape on a rectangular coordinate axis [vertex (0, 0), (1, 0), (1, 1), (0, 1)], the mapped plane is defined within this square region in the parameter plane, therefore a surface in real-space is expressed usually within the range of 0xe2x89xa6xcex1, xcex2xe2x89xa61. FIG. 2 shows that within the parameter plane (xcex1, xcex2), there are (m+1) points in direction xcex1 (xcex1=0,xcex1=xcex11,xcex1=xcex12, . . . , xcex1=1), and (n+1) points in direction xcex2 (xcex2=0, xcex2=xcex21, xcex2=xcex22, . . . , xcex2=1); a total of (m+1)xc3x97(n+1) control points are set, and that the mapped plane (vertex Poo, Pmo, Pmn, Pon) is defined corresponding to these control points. The point P (x, y, z) on the mapped plane in real-space is the function of parameters xcex1, xcex2 using the rectangular coordinate system, and can be expressed by the following equations (3):
x=X(xcex1, xcex2) y=Y(xcex1, xcex2) z=Z(xcex1, xcex2)xe2x80x83xe2x80x83(3)
Most of the free curved surface used by the currently-applied CAD system is called a NURBS (non-uniform rational B-spline) surface, and is expressed by the following formula (4):                               S          ⁡                      (                          α              ,              β                        )                          =                                            ∑                              i                =                0                            m                        ⁢                                          ∑                                  j                  =                  0                                n                            ⁢                              xe2x80x83                            ⁢                                                Nik                  ⁡                                      (                    α                    )                                                  ⁢                                  Njk                  ⁡                                      (                    β                    )                                                  ⁢                WijPij                                                                        ∑                              i                =                0                            m                        ⁢                                          ∑                                  j                  =                  0                                n                            ⁢                              xe2x80x83                            ⁢                                                Nik                  ⁡                                      (                    α                    )                                                  ⁢                                  Njk                  ⁡                                      (                    β                    )                                                  ⁢                Wij                                                                        (        4        )            
wherein:
Nik (xcex1), Njk (xcex2); so-called a B-spline function
Wij; weight function,
Pij; surface control point (position vector),
m+1, n+1: the number of control points in directions xcex1 and xcex2, the total number of control points being (m+1)xc3x97(n+1).
According to the prior art CAD method, as shown in FIG. 2, a rectangular coordinate system is used for the parameter plane (xcex1, xcex2), and when defining a surface having a complex local shape, the number nxc3x97m of the control points are increased for example to 10xc3x9710, . . . , or 50xc3x97100 according to the level of complexity.
Moreover, the straight lines drawn parallel to the vertical axis and the horizontal axis in the parameter plane (xcex1, xcex2) [that is, lines xcex1=0, xcex1=1, xcex2=0 or xcex2=1 (expressing the boundary of the surface in real-space), or lines expressed by a fixed value of xcex1 or a fixed value of xcex2] is expressed by a higher function of parameters xcex1, xcex2 in mapping space (real-space). For example, according to methods such as the cubic Bezier patch or Coons patch, these lines in the parameter plane (xcex1, xcex2) are expressed by a cubic Bezier curve: cubic parametric curve. However, even according to this method, the mapped curve in real-space corresponding to a straight line (u=xcex1=xcex2) that diagonally cuts the parameter plane (xcex1, xcex2) expressed by xcex1=xcex2 becomes a sextic function expressed by the sextic equation of the parameter (u).
It is possible to continuously define a plural number of surface to the horizontal and vertical directions using the curved surface expressed by such curved method, but it is not possible to bond plural surface diagonally. In other words, the cubic Bezier curved surface defined by a group of infinite cubic Bezier curved lines may look like a group of sextic Bezier curved lines, and it is impossible to share the cubic curve and the sextic curve as the boundary between surfaces. Therefore, such conditions provide an extremely strict restriction to the creation of graphics.
Generally, the definition of the interior of a surface is not clear from a surface expressed with boundary lines. There are cases where a cross-sectional line (diagram) cutting the surface with a plane is used to evaluate the shape of the surface. However, coloring (shading) is a natural method to confirm the shape of a surface visually. Moreover, the virtual surface within the computer is realized by machining along the mathematically defined surface using an NC machine tool.
It is impossible to perform a consistent logical operation process according to the solid CAD method using various surfaces or by the conventional free curved surfaces defined by a complex formula. Therefore, as shown in FIG. 3, in the final step, the curved surface is resolved into small surface segments expressed by the minimum degree of freedom, or in other words, microplanes [normally, very small triangular surface elements] PT. All the curved surfaces of a solid is resolved into microplanes PT, and the operation process is carried out using a linear discrete process approximating this group of microplanes [called xe2x80x9cpolygonxe2x80x9d] PP. The result of the operation is approximated by planes and lines. As explained, the currently applied CAD method utilizes a polygon PP where triangular surfaces PT formed by cutting portions of a plane defined by infinite expansion are connected so as to approximately express the curved surface, and a surface expression representing a wide space (such as NURBS surface) is used to control the alignment of the triangular microplanes PT.
Moreover, when shading is to be performed according to the conventional CAD method or CG (computer graphics), the color (shadow level) at each vertex of the polygon is computed, and continuous gradation process (glow shade, phon shade) is performed to the rest of the area. According to the conventional computer technology, it is not possible to evaluate the continuity of the surfaces visually. As explained, the linear-discrete approximation according to such CAD technology also has various problems for application to an NC process where a machine tool is controlled to cut out the desired shape.
The solid CAD method has the following characteristics:
(1) a graphic is created by Boolean operation superposing basic two-or two-and-a-half dimensional graphics (primitives) such as a cylinder, a cone or a hexahedron;
(2) a fillet surface must be formed to the area where two surfaces are superposed; however, such fillet process is irrational and not suited for designing;
(3) it is necessary according to the curved surface processing to define a substantially quadrilateral surface, and to adjust the shape of the surface through trimming; and
(4) the operation processes above are approximation computations using polygonal approximation (linear-discrete approximation) applying linear algebra.
The advantage of the conventional method is that the process of designing can be reproduced from the beginning. However, the quantity of the data to be handled is grand, and the load for operation processes by the computer is too much, and there is no consistency in the handling of the surfaces.
Taking the above problems into consideration, the present invention applies a basic theory called xe2x80x9ctopologyxe2x80x9d to the three-dimensional CAD system, thereby providing a 3D CAD system capable of reducing the amount of data greatly, cutting down the load for operation processes of the computer, and providing consistency in the handling of the surfaces.
According to the basic characteristics of the present invention, there is provided a 3D-CAD system comprising means for setting a point element, and further setting a curved line (including a straight line) element, a curved surface (including a flat surface) element or a solid element each defined by linear, area or volume coordinate parameters as a basic graphic element; means for connecting a plurality of the basic graphic elements, thereby setting a basic graphic; and a means for deforming the basic graphic elements constituting the basic graphic while maintaining continuous differentiability thereof, thereby creating a desired solid graphic.
The above-mentioned basic graphic element is expressed by an nth degree equation (n is an integer of 2 or more) of the coordinate parameters; that is, the generated solid graphic is defined by a group of points having space coordinates expressed by a linear combination of same degree (N) monominals of the coordinate parameters.
Moreover, the point element has a three-dimensional position coordinate, the line element has data designating the point elements on both ends thereof (end pointers) and data representing the relative position of an intermediate control point (intermediate point control vector/line control vector), the surface element has data designating the line (border line/external line/periphery line) elements constituting said surface (border line/external line/periphery line pointer) and data representing the relative positional coordinates of inner-surface control points (inner control vectors), the solid element has data representing the data designating the surface (boundary surface/external surface/periphery surface) elements constituting the solid, and each of the point element, the line element and the surface element further has a reference counter (reference count/depending master number) showing how many other elements refer to said specific element.
Moreover, according to the main characteristics of the present invention, a recording medium for a three-dimensional CAD system is provided, to which is recorded a program comprising: a step of setting a point element, and further setting a line element, a surface element or a solid element each defined by linear, area or volume coordinate parameters as a basic graphic element; a step of connecting a plurality of basic graphic elements, thereby setting a basic graphic; and a step of deforming the basic graphic elements constituting the basic graphic while maintaining continuous differentiability thereof, thereby creating a desired solid graphic.
According to the present invention, line elements, surface elements or solid elements each defined by line, area or volume coordinate parameters are set as basic graphic elements (referred to as xe2x80x9celement graphicsxe2x80x9d in the embodiment), and the basic graphic elements are mutually connected in order to form a compound graphic (referred to as xe2x80x9cparts graphicsxe2x80x9d or xe2x80x9cpartsxe2x80x9d in the embodiment) defined continuously by plural coordinate parameters, and these graphics are deformed so as to create the desired solid form. Accordingly, the surface element can express a wide region compared to the surface processing method of the conventional CAD system. Moreover, since patches are continuously connected to define a space graphic, that is, the present invention defines a continuously differentiable space graphic, and the patch can approximately express every surface, the surfaces can be handled consistently. Therefore, the present invention greatly reduces the data quantity for describing the graphic, and further reduces the load for operation processes of the computer.
Moreover, according to the invention, when the created solid graphic is defined by a group of points having space coordinates expressed by the cubic equation of the coordinate parameters, a sufficiently practical three-dimensional graphic expression is obtained without having to increase the number of operation more than necessary, enabling to control the surfaces while maintaining the continuous bond of tangents at the end of the surfaces.
According to the invention, the point elements have three-dimensional coordinate data, the line elements have end point pointers and intermediate control point data, the surface elements have boundary line pointers and inner-surface control point data, and the solid elements have data expressing the boundary surface pointers. Further, the point elements, the line elements and the surface elements have reference counter data. Therefore, when an element is to be deleted, the reference counter data is referred to so as to confirm whether or not this element is a constituent of other elements, thereby effectively determining whether or not to delete the element.